package com.ruoyi.develop.payRecordBuyDetail.service.impl;

import java.util.List;

import com.ruoyi.common.utils.StringUtils;
import com.ruoyi.common.utils.DateUtils;
import com.ruoyi.common.utils.uuid.IdUtils;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import com.ruoyi.develop.payRecordBuyDetail.mapper.PayRecordBuyDetailMapper;
import com.ruoyi.develop.payRecordBuyDetail.domain.PayRecordBuyDetail;
import com.ruoyi.develop.payRecordBuyDetail.service.IPayRecordBuyDetailService;

/**
 * 付款记录和付款申请明细关系Service业务层处理
 *
 * @author qh
 * @date 2025-04-15
 */
@Service
public class PayRecordBuyDetailServiceImpl implements IPayRecordBuyDetailService {
    @Resource
    private PayRecordBuyDetailMapper payRecordBuyDetailMapper;

    /**
     * 查询付款记录和付款申请明细关系
     *
     * @param payRecordId 付款记录和付款申请明细关系主键
     * @return 付款记录和付款申请明细关系
     */
    @Override
    public PayRecordBuyDetail selectByPayRecordId(String payRecordId) {
        return payRecordBuyDetailMapper.selectByPayRecordId(payRecordId);
    }

    /**
     * 查询付款记录和付款申请明细关系列表
     *
     * @param entity 付款记录和付款申请明细关系
     * @return 付款记录和付款申请明细关系
     */
    @Override
    public List<PayRecordBuyDetail> selectList(PayRecordBuyDetail entity) {
        return payRecordBuyDetailMapper.selectList(entity);
    }

    /**
     * 新增付款记录和付款申请明细关系
     *
     * @param entity 付款记录和付款申请明细关系
     * @return 结果
     */
    @Override
    public int insert(PayRecordBuyDetail entity) {
        return payRecordBuyDetailMapper.insert(entity);
    }

    /**
     * 修改付款记录和付款申请明细关系
     *
     * @param entity 付款记录和付款申请明细关系
     * @return 结果
     */
    @Override
    public int update(PayRecordBuyDetail entity) {
        return payRecordBuyDetailMapper.update(entity);
    }

    /**
     * 批量删除付款记录和付款申请明细关系
     *
     * @param payRecordIds 需要删除的付款记录和付款申请明细关系主键
     * @return 结果
     */
    @Override
    public int deleteByPayRecordIds(String[] payRecordIds) {
        return payRecordBuyDetailMapper.deleteByPayRecordIds(payRecordIds);
    }

    /**
     * 删除付款记录和付款申请明细关系信息
     *
     * @param payRecordId 付款记录和付款申请明细关系主键
     * @return 结果
     */
    @Override
    public int deleteByPayRecordId(String payRecordId) {
        return payRecordBuyDetailMapper.deleteByPayRecordId(payRecordId);
    }
}
